package com.byxy.po;
//博客表

import com.gitee.sunchenbin.mybatis.actable.annotation.Column;
import com.gitee.sunchenbin.mybatis.actable.annotation.Table;
import com.gitee.sunchenbin.mybatis.actable.constants.MySqlTypeConstant;
import lombok.Data;

import javax.persistence.*;
import java.io.Serializable;
import java.util.Date;
import java.util.List;

@Table(name = "Blog")
@Data
public class Blog{
    @Id
    @Column(name = "id", type = MySqlTypeConstant.INT, length = 30, isKey = true, isAutoIncrement = true)
    private String id;// 博客id
    @Column(name = "article_title", type = MySqlTypeConstant.VARCHAR, length = 50)
    private String articleTitle;// 文章標題
    @Column(name = "article_content", type = MySqlTypeConstant.TEXT)
    private String articleContent;// 文章内容
    @Column(name = "give_like", type = MySqlTypeConstant.INT, length = 12)
    private Integer giveLike;// 点赞
    @Column(name = "share", type = MySqlTypeConstant.INT, length = 15)
    private Integer share;// 分享
    private boolean appreciation;//赞赏
    private boolean reprinted;//转载
    private boolean commentabled;//评论
    @Column(name = "published",type = MySqlTypeConstant.CHAR,length = 10)
    private boolean published;//状态：保存或发布
    private boolean recommend;//推荐
    @Column(name = "user_id", type = MySqlTypeConstant.INT, length = 15)
    private Integer userId;
    @Column(name = "viewed", type = MySqlTypeConstant.INT, length = 15)
    private Integer viewed;// 浏览次数
    @Column(name = "publ_time", type = MySqlTypeConstant.DATETIME)
    private Date publTime;// 发表时间
}
